package com.zzyl.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.github.pagehelper.Page;
import com.zzyl.entity.NursingProject;
import com.zzyl.vo.NursingProjectVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface NursingProjectMapper extends BaseMapper<NursingProject> {


    /**
     * 分页查询
     * @param name
     * @param status
     * @return
     */
    Page<NursingProjectVo> getByPage(String name, Integer status);

    /**
     * 添加护理项目
     * @param nursingProject
     * @return
     */
    int save(NursingProject nursingProject);

    int updateProject(NursingProject nursingProject);

    NursingProjectVo getById(Long id);

    @Select("select * from nursing_project")
    List<NursingProject> list();
}
